<template>
  <div style="background-color: #ffefcf; padding: 10px">
    <el-breadcrumb separator-class="el-icon-arrow-right">
      <el-breadcrumb-item :to="{ path: '/' }">首页</el-breadcrumb-item>
      <el-breadcrumb-item>我院硬件设施简介</el-breadcrumb-item>
    </el-breadcrumb>

    <div>
      <el-divider></el-divider><span style="color: #E6A23C;font-size: 36px">我院硬件设施简介</span>
      <div style="text-align: right">时间:2023/2/20 20:37</div>
      <el-divider></el-divider>
    </div>

    <div style="margin-bottom: 20px">
      <span style="color: #E6A23C;font-size: 25px;">(一) 管理团队</span>
    </div>

    <p style="line-height: 25px;text-indent: 2em;font-size: 16px">
      我院员工共<el-tag type="warning">{{this.staffCount}}</el-tag>人,
      其中院长<el-tag type="warning">{{this.staffPricidentCount}}</el-tag>名,
      副院长<el-tag type="warning">{{this.staffVicePricidentCount}}</el-tag>名,
      前台<el-tag type="warning">{{this.staffReceptionCount}}</el-tag>人,
      护工<el-tag type="warning">{{this.staffWorkCount}}</el-tag>人,
      行政后勤人员<el-tag type="warning">{{this.staffLogisiticCount}}</el-tag>人,
      保证充足人手为老人提供贴心服务. </p>

    <div style="margin:20px auto;align-items: center;text-align: center">
      <img src="../../../assets/equipment/equipment01.png" width="500"/>
      <div style="margin-top: 10px; ;font-size: 13px">  <b>我院管理团队</b></div>
    </div>

    <div style="margin-bottom: 20px">
      <span style="color: #E6A23C;font-size: 25px;">(二) 床位设施</span>
    </div>

    <p style="line-height: 25px;text-indent: 2em;font-size: 16px">
      我院主楼 "有依楼" 共<el-tag type="warning">{{this.floorCount}}</el-tag>层,
      共设有床位<el-tag type="warning">{{this.bedCount}}</el-tag>个,为广大老年人朋友
      提供充足的生活和活动空间.
    </p>


    <div style="margin:20px auto;align-items: center;text-align: center">
      <img src="../../../assets/equipment/equipment02.png" width="500"/>
      <div style="margin-top: 10px; ;font-size: 13px">  <b>"有依楼"</b></div>
    </div>

    <div style="margin:20px auto;align-items: center;text-align: center">
      <img src="../../../assets/equipment/equipment03.png"  width="500"/>
      <div style="margin-top: 10px; ;font-size: 13px">  <b>床位实拍</b></div>
    </div>










  </div>
</template>

<script>
export default {
  data() {
    return{
      bedCount:'0',
      floorCount:'0',
      staffCount:'0',
      staffPricidentCount:'0',
      staffVicePricidentCount:'0',
      staffReceptionCount:'0',
      staffWorkCount:'0',
      staffLogisiticCount:'0',


    };
  },
  methods:{
    loadBedCount(){
      let url = 'http://localhost:8080/static/bed-num';
      console.log('url = ' + url);
      this.axios.get(url).then((response) => {
        let responseBody = response.data;
        if (responseBody.state == 20000) {
          this.bedCount = responseBody.data;
          console.log(this.bedCount);
        }
      });
    },
    loadFloorCount(){
      let url = 'http://localhost:8080/static/floor-num';
      console.log('url = ' + url);
      this.axios.get(url).then((response) => {
        let responseBody = response.data;
        console.log(responseBody);
        if (responseBody.state == 20000) {
          this.floorCount = responseBody.data;
          console.log(this.floorCount);
        }
      });
    },
    loadStaffCount(){
      let url = 'http://localhost:8080/static/staff-num';console.log('url = ' + url);
      this.axios.get(url).then((response) => {let responseBody = response.data;console.log(responseBody);
        if (responseBody.state == 20000) {
          this.staffCount = responseBody.data;
          console.log(this.staffCount);}});
    },
    loadstaffPricidentCount(){
      let url = 'http://localhost:8080/static/'+'院长'+'/staff-num';console.log('url = ' + url);
      this.axios.post(url).then((response) => {let responseBody = response.data;console.log(responseBody);
        if (responseBody.state == 20000) {
          this.staffPricidentCount = responseBody.data;
          console.log(this.staffPricidentCount);}});
    },

    loadstaffVicePricidentCount(){
      let url = 'http://localhost:8080/static/'+'副院长'+'/staff-num';console.log('url = ' + url);
      this.axios.post(url).then((response) => {let responseBody = response.data;console.log(responseBody);
        if (responseBody.state == 20000) {
          this.staffVicePricidentCount = responseBody.data;
          console.log(this.staffVicePricidentCount);}});
    },

    loadstaffReceptionCount(){
      let url = 'http://localhost:8080/static/'+'前台'+'/staff-num';console.log('url = ' + url);
      this.axios.post(url).then((response) => {let responseBody = response.data;console.log(responseBody);
        if (responseBody.state == 20000) {
          this.staffReceptionCount = responseBody.data;
          console.log(this.staffReceptionCount);}});
    },

    loadstaffWorkCount(){
      let url = 'http://localhost:8080/static/'+'护工'+'/staff-num';console.log('url = ' + url);
      this.axios.post(url).then((response) => {let responseBody = response.data;console.log(responseBody);
        if (responseBody.state == 20000) {
          this.staffWorkCount = responseBody.data;
          console.log(this.staffWorkCount);}});
    },

    loadstaffLogisiticCount(){
      let url = 'http://localhost:8080/static/'+'后勤'+'/staff-num';console.log('url = ' + url);
      this.axios.post(url).then((response) => {let responseBody = response.data;console.log(responseBody);
        if (responseBody.state == 20000) {
          this.staffLogisiticCount = responseBody.data;
          console.log(this.staffLogisiticCount);}});
    },









  },
  mounted() {
    this.loadBedCount();
    this.loadFloorCount();
    this.loadStaffCount();
    this.loadstaffPricidentCount();
    this.loadstaffVicePricidentCount();
    this.loadstaffReceptionCount();
    this.loadstaffWorkCount();
    this.loadstaffLogisiticCount();
  }


}
</script>

<style scoped>

</style>